Skip to content

ASoC: SOF: IPC4: fix reversed pipeline trigger priority order - #5810

Closed
ujfalusi wants to merge 1 commit into
thesofproject:topic/sof-devfrom
ujfalusi:peter/sof/pr/ppl_priority_trigger
Closed

ASoC: SOF: IPC4: fix reversed pipeline trigger priority order#5810
ujfalusi wants to merge 1 commit into
thesofproject:topic/sof-devfrom
ujfalusi:peter/sof/pr/ppl_priority_trigger

Conversation

@ujfalusi

Copy link
Copy Markdown
Collaborator

The IPC4 definition of pipeline prioity is:
0 - highest priority
7 - lowest priority

RUNNING should use ascending order (highest priority first), otherwise descending order (lowest priority first) should be used.

Fixes: 4df7d6a ("ASoC: SOF: IPC4: sort pipeline based on priority")
Cc: stable@vger.kernel.org

The IPC4 definition of pipeline prioity is:
0 - highest priority
7 - lowest priority

RUNNING should use ascending order (highest priority first), otherwise
descending order (lowest priority first) should be used.

Fixes: 4df7d6a ("ASoC: SOF: IPC4: sort pipeline based on priority")
Cc: stable@vger.kernel.org
Signed-off-by: Peter Ujfalusi <peter.ujfalusi@linux.intel.com>

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Fixes IPC4 pipeline trigger sorting to match the documented priority semantics (0 = highest, 7 = lowest) by using ascending order for RUNNING transitions and descending order for non-RUNNING transitions (e.g., PAUSED/RESET). This corrects the reversed ordering introduced by the prior priority-sorting change and aligns behavior with the IPC4 specification.

Changes:

  • Adjust pipeline insertion ordering so SOF_IPC4_PIPE_RUNNING triggers pipelines in ascending priority (highest first).
  • Adjust SOF_IPC4_PIPE_PAUSED and SOF_IPC4_PIPE_RESET to trigger pipelines in descending priority (lowest first).
  • Clarify the intended ordering with comments in the priority insertion helper.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

@ujfalusi
ujfalusi marked this pull request as draft June 11, 2026 08:06

@kv2019i kv2019i left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The comment is misleading, but I think the order is intentionally this way and matches Intel reference code for IPC4. There is a delta how SOF FW handles this and this is discussed in the SOF FW PR thesofproject/sof#10868 (comment)

I don't think we should merge especially if we don't have plan to change the FW implementation.

@ujfalusi

ujfalusi commented Aug 7, 2026

Copy link
Copy Markdown
Collaborator Author

Closing

@ujfalusi ujfalusi closed this Aug 7, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants